home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus Special 23 / AMIGAplus Sonderheft 23 (2000)(Falke)(DE)[!].iso / Updates / AddOns / WormWars / Source / diff.h next >
C/C++ Source or Header  |  1999-11-08  |  5KB  |  139 lines

  1. /* $Filename:    WormWars/Source/diff.h $
  2.  * $VER:         WormWars 4.1 (20.4.99) $
  3.  * $Description: Header file for Worm Wars 4.1 for Amiga $
  4.  *
  5.  * © Copyright 1999 James R. Jacobs.
  6.  */
  7.  
  8. #include <exec/types.h>
  9.  
  10. /* SAME ON EACH PLATFORM --------------------------------------------------
  11.  
  12. types */
  13.  
  14. #define AGLOBAL                ;        // global (project-scope)
  15. #define MODULE                static    // external static (file-scope)
  16. #define PERSIST                static    // internal static (function-scope)
  17. typedef signed char            ABOOL;    // 8-bit signed quantity (replaces ABOOL)
  18. typedef signed char            SBYTE;    // 8-bit signed quantity (replaces Amiga BYTE)
  19. typedef signed short        SWORD;    // 16-bit signed quantity (replaces Amiga WORD)
  20. typedef signed long            SLONG;    /* 32-bit signed quantity (same as LONG)
  21.  
  22. DIFFERING ON EACH PLATFORM ------------------------------------------------
  23.  
  24. types */
  25.  
  26. typedef signed char            COLOUR;        // 8-bit signed
  27. typedef unsigned char        SCANCODE;    /* 8-bit unsigned
  28.  
  29. miscellaneous */
  30.  
  31. #define DEFAULTSET            "WormWars.fset"
  32. #define GAMEDELAY            16000L
  33. #define GAMEDELAYPERLEVEL     1000L
  34. #define FONTX                    8                // in pixels...
  35. #define FONTY                    8
  36. #define HISCOREDISTANCE           13
  37. #define SCREENXPIXEL          639
  38. #define SCREENYPIXEL          245
  39. #define SQUAREX                    9
  40. #define SQUAREY                    6
  41. #define STARTXPIXEL               83
  42. #define STARTYPIXEL               11
  43.  
  44. // scancodes
  45.  
  46. #define ALPHAONE            0x01    // row 1. alphabetic 1
  47. #define ALPHATWO            0x02    // row 1. alphabetic 2
  48. #define ALPHATHREE            0x03    // row 1. alphabetic 3
  49. #define ALPHAFOUR            0x04    // row 1. alphabetic 4
  50. #define ALPHAFIVE            0x05    // row 1. alphabetic 5
  51. #define ALPHASIX            0x06    // row 1. alphabetic 6
  52. #define ALPHASEVEN            0x07    // row 1. alphabetic 7
  53. #define ALPHAEIGHT            0x08    // row 1. alphabetic 8
  54. #define NUMERICZERO            0x0F    // row 5. numeric 0
  55. #define Q                    0x10    // row 2.
  56. #define W                    0x11    // row 2.
  57. #define E                    0x12    // row 2. erase
  58. #define I                    0x17    // row 2. insert
  59. #define O                    0x18    // row 2. open...
  60. #define P                    0x19    // row 2.
  61. #define NUMERICONE            0x1D    // row 5. numeric 1
  62. #define NUMERICTWO            0x1E    // row 5. numeric 2
  63. #define NUMERICTHREE        0x1F    // row 5. numeric 3
  64. #define A                    0x20    // row 3. save as...
  65. #define S                    0x21    // row 3. save
  66. #define D                    0x22    // row 3. delete
  67. #define F                    0x23    // row 3. effects
  68. #define K                     0x27    // row 3. append
  69. #define INTERNATIONALONE    0x2B    /* row 3. international key adj. to
  70.                                         Return (on some keyboards) */
  71. #define NUMERICFOUR             0x2D    // row 5. numeric 4
  72. #define NUMERICFIVE             0x2E    // row 5. numeric 5
  73. #define NUMERICSIX             0x2F    // row 5. numeric 6
  74. #define INTERNATIONALTWO    0x30    /* row 4. international key adj. to
  75.                                         Left Shift (on some keyboards) */
  76. #define Z                     0x31    // row 4.
  77. #define KEY_X                0x32    // row 4.
  78. #define C                    0x33    // row 4.
  79. #define V                    0x34    // row 4.
  80. #define N                    0x36    // row 4. new
  81. #define M                    0x37    // row 4. music
  82. #define NUMERICDOT            0x3C    // row 5. numeric .
  83. #define NUMERICSEVEN        0x3D    // row 5. numeric 7
  84. #define NUMERICEIGHT        0x3E    // row 5. numeric 8
  85. #define NUMERICNINE            0x3F    // row 5. numeric 9
  86. #define SPACEBAR            0x40    // row 4.
  87. #define ENTER                0x43    // row 5. numeric Enter
  88. #define RETURN                0x44    // row 2. alphabetic Return
  89. #define ESCAPE                0x45    // row 0.
  90. #define DELETE                0x46    // row 3.
  91. #define NUMERICMINUS        0x4A    // row 5. numeric -
  92. #define UP                    0x4C    // row 1.
  93. #define DOWN                0x4D    // row 4.
  94. #define RIGHT                0x4E    // row 3.
  95. #define LEFT                0x4F    // row 2.
  96. #define F1                    0x50    // row 0.
  97. #define F2                    0x51    // row 0.
  98. #define F3                    0x52    // row 0.
  99. #define F4                    0x53    // row 0.
  100. #define F5                    0x54    // row 0.
  101. #define F6                    0x55    // row 0.
  102. #define F7                    0x56    // row 0.
  103. #define F8                    0x57    // row 0.
  104. #define F10                    0x59    // row 0.
  105. #define NUMERICOPEN            0x5A    // row 0. numeric (
  106. #define NUMERICCLOSE        0x5B    // row 0. numeric )
  107. #define NUMERICSLASH        0x5C    // row 5. numeric /
  108. #define NUMERICASTERISK        0x5D    // row 5. numeric *
  109. #define NUMERICPLUS            0x5E    // row 5. numeric +
  110. #define HELP                0x5F    // row 0.
  111. #define FIRSTQUALIFIER        0x61
  112. #define LASTQUALIFIER        0x67
  113. #define KEYUP                0x80    // key release
  114.  
  115. // colours
  116.  
  117. #define BLACK         0
  118. #define WHITE         1
  119. #define DARKGREY     2
  120. #define LIGHTGREY     4
  121. #define ORANGE         5
  122. #define PURPLE         6
  123. #define DARKGREEN     8
  124. #define GREEN         9
  125. #define DARKRED        10
  126. #define RED            11
  127. #define DARKBLUE    12
  128. #define BLUE        13
  129. #define DARKYELLOW    14
  130. #define YELLOW        15
  131.  
  132. // AMIGA-ONLY -------------------------------------------------------------
  133.  
  134. #define JOYDELAY            50000L        // 1,000,000 / JOYDELAY = movement in squares per second
  135. #define MENUENTRIES               18
  136. #define SENTINEL                2        // not -1, 0 or 1
  137.  
  138. // Must have blank line at EOF.
  139.